' This program exported from BASIC Anywhere Machine (Version [5.2.3].[2024.09.09.00.00]) on 2025.02.22 at 00:18 (Coordinated Universal Time)
' Program by Charlie Veniot
' Using DRAW to "spirograph" ellipses
' Rotating the ellipses on an axis to create a colorful (32-bit) spherical shape with increasing color brightness
CONST center% = 500
CONST side% = center% * 2 + 1
CONST startAngle% = 45
SCREEN _NEWIMAGE( side%, side%, 27 )
FOR aE% = startAngle% TO 180 STEP 1
c% = _RGB32(0,0, 255 * ( aE% - startAngle% ) / ( 180 - startAngle% ) )
GOSUB 🖌DrawEllipse
SLEEP 0.001
NEXT aE%
END
🖌DrawEllipse:
FOR aG% = 0 TO 360 STEP 1
DRAW "BM " + center% + "," + center%
DRAW "B TA " + ( aE% + 90 + aG% ) + " U" + ( center% - 330)
DRAW "B TA " + ( 450 + 90 + aE% - aG% ) + " R" + ( center% - 250 )
CIRCLE ( POINT(0), POINT(1) ), 10, c%, , , , T
NEXT aG%
RETURN